﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using Lidgren.Network;
using Model.LiveControl;

namespace Network.Messages.LiveControl
{
    /// <summary>
    /// 
    /// </summary>
    public class MouseMoveMessage : MouseEventBase
    {
        public MouseMoveMessage()
            : base((ushort)CustomMessageType.MouseMoveMessage)
        {
        }
        public override void SetSomethingBeforeWrite()
        {
            MouseEventArgs.BtnFlag = MouseEventFlag.MOUSEEVENTF_ABSOLUTE | MouseEventFlag.MOUSEEVENTF_MOVE;
        }
        public long Now;

        public override void WritePayload(NetOutgoingMessage message)
        {
            base.WritePayload(message);
            message.Write(Now);

        }

        public override void ReadPayload(NetIncomingMessage message)
        {
            base.ReadPayload(message);
            Now = message.ReadInt64();

        }
    }
}
